package com.sykj.springboot.test.designMode.Observer1;

import lombok.Data;

@Data
public class HanFeiZi implements IHanFeiZi {

    //韩非子是否在吃饭，作为监控的判断标准
    private boolean breakfastFlag = false;
    //韩非子是否在娱乐
    private boolean haveFunFlag = false;



    @Override
    public void haveBreakFast() {
        System.out.println("韩非子：开始吃早饭");
        breakfastFlag = true;
    }

    @Override
    public void haveFun() {
        System.out.println("韩非子：开始娱乐了");
        haveFunFlag = true;
    }
}
